#!/bin/sh

set -x

#  1.  Generate CSF expansions
#      1.1 MR for 2s(2)2p, 2p(3)

rcsfgenerate <<EOF1
*
0
1s(2,i)2s(2,i)2p(1,i)
1s(2,i)2p(3,i)

2s,2p
1,3
0
n
EOF1

cp rcsf.out odd2.c

#        1.2 SD-MR for n=6

rcsfgenerate <<EOF3
*
0
1s(2,*)2s(2,*)2p(1,*)
1s(2,*)2p(3,*)

6s,6p,6d,6f,6g,6h
1,3
2
n
EOF3

cp rcsf.out odd.c

#       Split into odd3.c, odd4.c, odd5.c, odd6.c

rcsfsplit <<EOF5
odd
4
3s,3p,3d
3
4s,4p,4d,4f
4
5s,5p,5d,5f,5g
5
6s,6p,6d,6f,6g,6h
6
EOF5

##########################################

#  2.  Generate CSF expansions
#      2.1 for 2s2p(2)

rcsfgenerate <<EOF1
*
0
1s(2,i)2s(1,i)2p(2,i)

2s,2p
1,5
0
n
EOF1

cp rcsf.out even2.c

#        2.2 SD for n=6

rcsfgenerate <<EOF3
*
0
1s(2,*)2s(1,*)2p(2,*)

6s,6p,6d,6f,6g,6h
1,5
2
n
EOF3

cp rcsf.out even.c

#        Split into even3.c, even4.c, even5.c, even6.c

rcsfsplit <<EOF5
even
4
3s,3p,3d
3
4s,4p,4d,4f
4
5s,5p,5d,5f,5g
5
6s,6p,6d,6f,6g,6h
6
EOF5

